VERSION 5.00
Begin VB.Form Form1 
   AutoRedraw      =   -1  'True
   Caption         =   "Form1"
   ClientHeight    =   3060
   ClientLeft      =   48
   ClientTop       =   324
   ClientWidth     =   3936
   LinkTopic       =   "Form1"
   ScaleHeight     =   3060
   ScaleWidth      =   3936
   StartUpPosition =   3  'Windows Default
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Form_Click()
Dim myPrimeFactory As IPrimeFactory
Dim myPrime As IPrime

' Call MkParseDisplayName
Set myPrimeFactory = GetObject("clsid:10000013-0000-0000-0000-000000000001")

' Call IPrimeFactory::CreatePrime
Set myPrime = myPrimeFactory.CreatePrime(7)

Dim Count As Integer
For Count = 0 To 10
    ' Call IPrime::GetNextPrime
    Print myPrime.GetNextPrime  ' Displays 11
Next
End Sub

